package com.cardbaobao.cardbabyclient.ui.helper;

import android.text.TextUtils;

import com.cardbaobao.cardbabyclient.R;

/**
 * Created by Jiangzx on 2017/9/26 19:16.
 */

public class BankCardBgHelper {
    public static int getBankCardBgRes(String back_color){
        int res=R.mipmap.img_card_bg_blue;
        if(!TextUtils.isEmpty(back_color)){
            switch (back_color){
                case "1":
                    //红
                    res=R.mipmap.img_card_bg_red;
                    break;
                case "2":
                    //黄
                    res=R.mipmap.img_card_bg_yellow;
                    break;
                case "3":
                    //绿
                    res=R.mipmap.img_card_bg_green;
                    break;
                case "4":
                    //蓝色
                    res=R.mipmap.img_card_bg_blue;
                    break;
                case "5":
                    //紫色
                    res=R.mipmap.img_card_bg_purple;
                    break;
                default:
                    //默认蓝色
                    res= R.mipmap.img_card_bg_blue;
                    break;
            }
        }
        return res;
    }
}
